<!DOCTYPE html>
<html>
{include file="public/head" /}
<body class="zanpian-body">
<section class="content">
<div class="callout callout-title">
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
                <h4>{$nav.title}</h4>
                {notempty name="nav.remark"}
                <p>{$nav.remark}</p>
                {/notempty}
</div> 
<div class="panel-body" id="contents">
<div class="panel-tool pb15">
<div class="row">
              <div class="col-md-12 col-sm-12 col-xs-12">
                <div id="toolbar" class="toolbar">
                <a href="{:url('up')}" form="#list" class="btn btn-primary btn-disabled ajax-post disabled">更新</a> <a href="{:url('add')}" data-name="添加配置" class="btn btn-success btn-add btn-editone"><i class="fa fa-plus"></i> 添加</a> <a  href="{:url('del')}" form="#list" class="confirm btn btn-danger btn-del btn-disabled ajax-post disabled"><i class="fa fa-trash"></i> 删除</a><span id="selectedChks">已选择<strong></strong>记录</span>
                </div>
                <!-- /.toolbar -->
              </div>
            </div>

</div>
<!-- /.panel-tool -->
    <div class="tab-content">
              <form id="list" method="post">
                <table id="table" class="table table-striped table-bordered table-hover" style="margin-top: 0px;" width="100%">
                   <thead>
                    <tr style="height:45px;">
                      <th style="text-align:center;vertical-align: middle; width:5%">
                      <label class="pretty success">
	                   <input type="checkbox" id="checkall" class="delcheckall"> 
	                    <label><i class="mdi mdi-check"></i></label>
	                  </label>
                      </th>
                      <th style="text-align:center;vertical-align: middle;">ID</th>
                      <th style="text-align:center;vertical-align: middle;width:20%">类型名</th>
                      <th style="text-align:center;vertical-align: middle;" ><a href="javascript:;" class="btn btn-success btn-xs btn-toggle"><i class="fa fa-chevron-up"></i></a></th>
                      <th style="text-align:center;vertical-align: middle;width:80px" class="hidden-xs">排序</th>
                      <th style="text-align:center;vertical-align: middle;width:20%" class="hidden-xs">中文名</th>
                      <th style="text-align:center;vertical-align: middle;width:20%" class="hidden-xs">拼音名</th> 
                      <th style="text-align:center;vertical-align: middle;">操作</th>
                    </tr>
                  </thead>                
               <tbody>
                {notempty name="list"}
                {volist name="list" id="mcat"}
                <tr>
                <td style="text-align:center;vertical-align: middle;">分类</td>
                <td style="text-align:center;vertical-align: middle;">{$mcat.list_id}</td>
                <td style="text-align:center;vertical-align: middle;padding-left:3%;text-align:left;">{$mcat['list_name']}&nbsp;&nbsp;(<font color="red">{$mcat['total']}</font>)<a style="color:#F30;"  data-name="添加类型" href="{:url('add',array('id'=>$mcat['list_id']))}" class="btn-editone"><i class="fa fa-plus" style="color:#F30; margin-left:8px;"></i></a></td>
                <td style="text-align:center;vertical-align: middle;""><a href="javascript:;" data-id="{$mcat.list_id}" data-pid="0" class="btn btn-xs btn-success btn-node-sub"><i class="fa fa-sitemap"></i></a>
                </td>
                <td style="text-align:center;vertical-align: middle;" class="hidden-xs"></td>
                <td style="text-align:center;vertical-align: middle;" class="hidden-xs"></td>
                <td style="text-align:center;vertical-align:middle;" class="hidden-xs">&nbsp;</td>
                <td style="text-align:center;vertical-align:middle;">
                <a  href="{:url('clear',array('id'=>$mcat['list_id']))}" target-form="ids" class="confirm btn btn-danger btn-xs confirm ajax-post"><i class="fa fa-trash"></i> 清空</a> </td>
              </tr>
              {volist name="mcat.son" id="mcid"}
                <tr style="display:none;">
                
            <td class="bs-checkbox" style="text-align:center;vertical-align:middle; font-size:14px">
                <label class="pretty success">
                <input name="id[]" type="checkbox" value="{$mcid['m_cid']}" id="checkbox"> 
	            <label><i class="mdi mdi-check"></i></label>
	            </label>
                <input type="hidden" name="m_list_id[{$mcid.m_cid}]"  value="{$mcid['m_list_id']|default=''}">
                </td>
                <td style="text-align:center;vertical-align: middle;">{$mcid.m_cid}</td>
                <td  style="text-align:center;vertical-align: middle;padding-left:3%;text-align:left;">├─&nbsp;{$mcid['m_name']}</td>
                <td style="text-align:center;vertical-align: middle;"><a href="javascript:;" data-id="{$mcid.m_cid}" data-pid="{$mcat.list_id}" class="btn btn-xs btn-default disabled"><i class="fa fa-sitemap"></i></a></td>
                <td style="text-align:center;vertical-align: middle;" class="hidden-xs">
                <input name="m_order[{$mcid.m_cid}]" class="form-control input-sm" value="{$mcid.m_order}" type="text" style="text-align:center; margin:0 auto;width:70%;"></td>
                
                <td style="text-align:center;vertical-align: middle;" class="hidden-xs"><input name="m_name[{$mcid.m_cid}]" class="form-control input-sm" value="{$mcid.m_name}" type="text" style="text-align:center; width:70%; margin:0 auto"></td> 
                <td style="text-align:center;vertical-align: middle;" class="hidden-xs"><input name="m_ename[{$mcid.m_cid}]" class="form-control input-sm" value="{$mcid.m_ename}" type="text" style="text-align:center; width:70%; margin:0 auto"></td>
                <td style="text-align:center;vertical-align: middle;">
                <a data-name="编辑类型" href="{:url('edit',array('id'=>$mcid['m_cid']))}" class="btn btn-success btn-editone btn-xs"><i class="fa fa-pencil"></i></a>
                <a  href="{:url('del',array('id'=>$mcid['m_cid']))}" class="confirm btn btn-danger btn-xs confirm ajax-post"><i class="fa fa-trash"></i></a></td>
              </tr>
              {/volist}
                 </tr>                
                     {/volist}
                 {else/}<tr><td style="text-align:center;vertical-align: middle;" colspan="10" >抱歉，没有找到相关内容！</td></tr>{/notempty}
            </tbody>
                </table>
              </form>
            </div>
    
         </div>
         <!-- /.panel-body --> 
        </section>
{include file="public/footer" /}
<script type="text/javascript">
$(document).ready(function(){
	zanpian.cms.mcat();
});	
</script>
</body>
</html>
